<?php
function yearstr($year){
    $data = array();
    $data['first'] = strtotime("$year-01-01");
    $data['last'] = strtotime("$year-12-31");
    return $data;
}